Skip to content

chore(fspy): cleanup unused code on Windows#37

Merged
branchseer merged 6 commits intomainfrom
11-19-test_fspy_flatten_accesse_modes_before_asserting
Nov 19, 2025
Merged

chore(fspy): cleanup unused code on Windows#37
branchseer merged 6 commits intomainfrom
11-19-test_fspy_flatten_accesse_modes_before_asserting

Conversation

@branchseer
Copy link
Member

@branchseer branchseer commented Nov 19, 2025

TL;DR

Improved file access tracking for Windows process creation and fixed path access detection in tests.

What changed?

  • Renamed subprocess test to read_in_subprocess and added a new read_program test to verify program file access detection
  • Enhanced assert_contains in test utilities to properly handle access mode comparison
  • Added Windows-specific tests for CreateProcessA and CreateProcessW functions
  • Removed unused stack_once.rs module and simplified process creation hooks
  • Fixed a re-entrance detection issue in process creation hooks by using thread-local state
  • Simplified NativeStr by removing the unused ANSI string support, as Windows paths are primarily handled as wide strings

How to test?

  • Run the existing and new tests on Windows to verify process creation hooks work correctly
  • Verify that file access tracking properly detects program file access when creating processes

Why make this change?

The previous implementation had issues with detecting program file access during process creation on Windows. This change improves the reliability of file access tracking by simplifying the hook implementation and removing unnecessary complexity. The tests now properly verify that the system correctly tracks file access when creating processes, which is essential for accurate dependency tracking.

Copy link
Member Author

branchseer commented Nov 19, 2025

This stack of pull requests is managed by Graphite. Learn more about stacking.

@branchseer branchseer marked this pull request as ready for review November 19, 2025 01:42
@branchseer branchseer changed the title test(fspy): flatten accesse modes before asserting chore(fspy): cleanup unused code on Windows Nov 19, 2025
@branchseer branchseer mentioned this pull request Nov 19, 2025
@branchseer branchseer merged commit c38d9f4 into main Nov 19, 2025
6 checks passed
@Brooooooklyn Brooooooklyn deleted the 11-19-test_fspy_flatten_accesse_modes_before_asserting branch December 11, 2025 06:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants